<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>语言包编辑器</title>
    <link rel="stylesheet" href="style.css">
    <script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
</head>
<body>
    <div class="fixed-header">
        <div class="fixed-header-inner">
            <h1>语言包编辑器</h1>
            <div class="buttons-container">
                <label for="file-upload" class="upload-btn">上传语言包（json文件）</label>
                <input type="file" id="file-upload" accept=".json" multiple style="display: none;">
                <button id="clear-all">清空</button>
                <button id="clear-changes">清空改动标记</button>
                <button id="complete" class="complete-btn">完成</button>
            </div>
        </div>
    </div>

    <div class="main-content">
        <div class="container">
            <div class="table-container">
                <table id="language-table">
                    <thead>
                        <tr>
                            <th contenteditable="false">序号</th>
                            <th contenteditable="false">字段</th>
                        </tr>
                    </thead>
                    <tbody></tbody>
                </table>
            </div>
        </div>

        <div class="sidebar-ad">
            <!-- 广告位内容 -->
        </div>
    </div>

    <!-- 弹窗代码保持不变 -->
    <!-- 完成弹窗 -->
    <div id="complete-modal" class="modal">
        <div class="modal-content">
            <span class="close-btn">&times;</span>
            <h2>生成的语言包</h2>
            <div class="json-container"></div>
        </div>
    </div>

    <!-- 清空确认弹窗 -->
    <div id="confirm-modal" class="modal">
        <div class="modal-content small-modal">
            <h3>确认清空</h3>
            <p>是否清空所有数据，无法复原</p>
            <div class="modal-buttons">
                <button id="confirm-yes">确认</button>
                <button id="confirm-no">取消</button>
            </div>
        </div>
    </div>

    <!-- 退出提醒弹窗 -->
    <div id="exit-modal" class="modal">
        <div class="modal-content small-modal">
            <h3>确认退出</h3>
            <p>现在退出内容将会丢失</p>
            <div class="modal-buttons">
                <button id="exit-stay">留在页面</button>
                <button id="exit-leave">离开</button>
            </div>
        </div>
    </div>

    <!-- 黏贴整列弹窗 -->
    <div id="paste-modal" class="modal">
        <div class="modal-content">
            <span class="close-btn">&times;</span>
            <h2>黏贴整列数据</h2>
            <p>请输入要黏贴的数据，每行对应一个字段的值：</p>
            <textarea id="paste-textarea" rows="15" style="width: 100%; margin-bottom: 15px;"></textarea>
            <div class="modal-buttons">
                <button id="paste-confirm">确认黏贴</button>
                <button id="paste-cancel">取消</button>
            </div>
        </div>
    </div>
    <script src="script.js"></script>
</body>
</html>